package com.zzzyh.forumsystemclient.services;

import com.zzzyh.forumsystemclient.model.Resource;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface IResourceService {
    List<Resource> listByCategory(Integer pageNum, Integer pageSize, Integer category);

    Integer totalByCategoryId(Integer category);

    void add(Resource resource);

    void increaseDownload(@Param("resourceId") Integer resourceId);

    void increaseView(Integer resourceId);

    List<Resource> listByCategoryName(Integer pageNum, Integer pageSize, Integer category, String name);

    Integer totalByCategoryIdAndName(@Param("category") Integer category, @Param("name") String name);
}
